﻿<form id="pagerForm" method="post" action="@ViewBag.ThisUrl">
<input type="hidden" name="pageNum" value="1" />
<input type="hidden" name="numPerPage" value="@ViewBag.pagination.NumPerPage" />
<input type="hidden" name="orderField" value="@ViewBag.pagination.OrderField" />
<input type="hidden" name="keywords" value="@ViewBag.pagination.Keywords"/>
@RenderSection("PagerFormKey", required: true)
</form>
<div class="pageHeader">
    <form rel="pagerForm" onsubmit="return navTabSearch(this);" action="@ViewBag.ActionUrl" method="post">
    <div class="searchBar">
        <ul class="searchContent">
        </ul>
        <div class="subBar">
            <ul>
                <li>
                    <div class="buttonActive">
                        <div class="buttonContent">
                            <button type="submit">
                                检索</button></div>
                    </div>
                </li>
            </ul>
        </div>
    </div>
    </form>
</div>
<div class="pageContent">
    <div class="panelBar">
        <ul class="toolBar">
            @if (!string.IsNullOrEmpty(ViewBag.AddActionUrl))
            {
                <li><a class="add" href="@ViewBag.AddActionUrl"target="navTab" rel="@ViewBag.rel" ><span>添加</span></a></li>
            }
            @if (!string.IsNullOrEmpty(ViewBag.DeleteActionUrl))
            { 
                <li><a class="delete" href="@ViewBag.DeleteActionUrl" target="ajaxTodo" title="确定要删除吗？" warn="请选择一行数据">
                    <span>删除</span></a></li>
            }
            @if (!string.IsNullOrEmpty(ViewBag.EditActionUrl))
            {
                <li><a class="edit" href="@ViewBag.EditActionUrl" target="navTab" warn="请选择一行数据"><span>修改</span></a></li>
            }
            @*<li class="line">line</li>*@
        </ul>
    </div>
    <div layouth="116">
        <table class="list" width="98%" targettype="navTab" asc="asc" desc="desc">
            @RenderBody()
        </table>
    </div>
    <div class="panelBar">
        <div class="pages">
            <span>显示</span>
            <select name="numPerPage" onchange="navTabPageBreak({numPerPage:this.value})">
             <option value="@ViewBag.pagination.NumPerPage">-@ViewBag.pagination.NumPerPage-</option>
                <option value="10">10</option>
                <option value="20">20</option>
                <option value="50">50</option>
                <option value="100">100</option>
                <option value="200">200</option>
            </select>
            <span>共 @ViewBag.pagination.TotalCount 条</span>
        </div>
        <div class="pagination" targetType="navTab" totalCount="@ViewBag.pagination.TotalCount " numPerPage="@ViewBag.pagination.NumPerPage" pageNumShown="@ViewBag.pagination.PageNumShown" currentPage="@ViewBag.pagination.PageNum">
        </div>
    </div>
</div>
